﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using XWG.Framework.DatabaseHelper;

namespace XWG.JWBST.JWBSTManagementApp.Application
{
    public partial class FAQ : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {

            if (!IsPostBack)
            {
                DataList1.DataKeyField = "id";
                DataList1.DataSource = Bind_List();
                DataList1.DataBind();
            }
        }

        /// <summary>
        /// dataList绑定
        /// </summary>
        /// <returns></returns>
        public DataTable Bind_List()
        {
            DataAccess da = new DataAccess();
            string strSql = "select t.rowid,t.* from TB_BST_ONLINE_ASK t where iscjwt='1'";
            DataTable dt = da.ExecuteDataset(true, CommandType.Text, strSql).Tables[0];
            return dt == null ? null : dt;
        }
    }
}